﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.Text;

namespace FDSimpleModelGenerator.Entities.CreateTables
{
    /// <summary>
    /// 创建的表信息
    /// </summary>
    [Table("gen_table")]
    public class Table : Entity
    {
        /// <summary>
        /// 表名
        /// </summary>
        public string Name { get; set; }

        /// <summary>
        /// 表备注
        /// </summary>
        public string Description { get; set; }

        /// <summary>
        /// 执行建表Sql
        /// </summary>
        public bool ExecuteSql { get; set; }

        /// <summary>
        /// 存在表则删除
        /// </summary>
        public bool DeleteExists { get; set; }

        /// <summary>
        /// 数据库名
        /// </summary>
        public string Database { get; set; }

        /// <summary>
        /// 列信息
        /// </summary>
        public IEnumerable<Column> Columns { get; set; }


        /// <summary>
        /// 索引信息
        /// </summary>
        public IEnumerable<ColumnIndex> Indexes { get; set; }
    }
}
